{
 "cells": [
  {
   "metadata": {
    "ExecuteTime": {
     "end_time": "2024-09-10T02:37:02.572253Z",
     "start_time": "2024-09-10T02:37:02.320080Z"
    }
   },
   "cell_type": "code",
   "source": "import pandas as pd",
   "id": "400c682aca37de41",
   "outputs": [],
   "execution_count": 2
  },
  {
   "cell_type": "code",
   "id": "initial_id",
   "metadata": {
    "collapsed": true,
    "ExecuteTime": {
     "end_time": "2024-09-10T02:37:03.123198Z",
     "start_time": "2024-09-10T02:37:03.100284Z"
    }
   },
   "source": [
    "acl_files = [\n",
    "        'data/nlp/raw/2017_ACL.csv',\n",
    "        'data/nlp/raw/2018_ACL.csv',\n",
    "        'data/nlp/raw/2019_ACL.csv',\n",
    "        'data/nlp/raw/2020_ACL.csv',\n",
    "        'data/nlp/raw/2021_ACL.csv',\n",
    "        'data/nlp/raw/2022_ACL.csv',\n",
    "        'data/nlp/raw/2023_ACL.csv'\n",
    "    ]\n",
    "\n",
    "acl_data = pd.concat([pd.read_csv(file) for file in acl_files], ignore_index=True)\n",
    "texts = acl_data[\"abstract\"].astype(\"str\").to_list()\n",
    "\n",
    "with open('data/nlp/raw/abstracts.txt', 'w') as f:\n",
    "        texts = [text.replace('\\n', ' ') for text in texts]\n",
    "        for text in texts:\n",
    "                f.write(text + '\\n')"
   ],
   "outputs": [],
   "execution_count": 3
  },
  {
   "metadata": {},
   "cell_type": "code",
   "outputs": [],
   "execution_count": null,
   "source": "",
   "id": "87477eb3f607e827"
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 2
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython2",
   "version": "2.7.6"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 5
}
